home *** CD-ROM | disk | FTP | other *** search
/ William Shakespeare - The Complete Works / William Shakespeare - The Complete Works on CD-ROM.iso / classic / form3a.frm < prev    next >
Text File  |  1994-09-21  |  16KB  |  649 lines

  1. VERSION 2.00
  2. Begin Form Form3 
  3.    Caption         =   "William Shakespeare: The Complete Works"
  4.    ClientHeight    =   3855
  5.    ClientLeft      =   1260
  6.    ClientTop       =   1785
  7.    ClientWidth     =   9510
  8.    Height          =   4545
  9.    Left            =   1200
  10.    LinkTopic       =   "Form3"
  11.    MaxButton       =   0   'False
  12.    MinButton       =   0   'False
  13.    ScaleHeight     =   257
  14.    ScaleMode       =   3  'Pixel
  15.    ScaleWidth      =   634
  16.    Top             =   1155
  17.    Width           =   9630
  18.    WindowState     =   2  'Maximized
  19.    Begin Timer Timer2 
  20.       Enabled         =   0   'False
  21.       Interval        =   100
  22.       Left            =   1500
  23.       Top             =   2640
  24.    End
  25.    Begin PictureBox picCursorMask1 
  26.       Height          =   516
  27.       Left            =   1800
  28.       Picture         =   FORM3A.FRX:0000
  29.       ScaleHeight     =   32
  30.       ScaleMode       =   3  'Pixel
  31.       ScaleWidth      =   32
  32.       TabIndex        =   8
  33.       Top             =   780
  34.       Visible         =   0   'False
  35.       Width           =   516
  36.    End
  37.    Begin PictureBox picCursor1 
  38.       AutoRedraw      =   -1  'True
  39.       Height          =   516
  40.       Left            =   900
  41.       Picture         =   FORM3A.FRX:0302
  42.       ScaleHeight     =   32
  43.       ScaleMode       =   3  'Pixel
  44.       ScaleWidth      =   32
  45.       TabIndex        =   7
  46.       Top             =   900
  47.       Visible         =   0   'False
  48.       Width           =   516
  49.    End
  50.    Begin CommonDialog CMDialog1 
  51.       Left            =   420
  52.       Top             =   2640
  53.    End
  54.    Begin Timer Timer1 
  55.       Enabled         =   0   'False
  56.       Interval        =   1000
  57.       Left            =   480
  58.       Top             =   1740
  59.    End
  60.    Begin CommandButton TopBar 
  61.       Caption         =   "&Biography"
  62.       FontBold        =   0   'False
  63.       FontItalic      =   0   'False
  64.       FontName        =   "MS Sans Serif"
  65.       FontSize        =   8.25
  66.       FontStrikethru  =   0   'False
  67.       FontUnderline   =   0   'False
  68.       Height          =   360
  69.       Index           =   1
  70.       Left            =   1500
  71.       TabIndex        =   6
  72.       Top             =   0
  73.       Width           =   1536
  74.    End
  75.    Begin CommandButton TopBar 
  76.       Caption         =   "&Search"
  77.       FontBold        =   0   'False
  78.       FontItalic      =   0   'False
  79.       FontName        =   "MS Sans Serif"
  80.       FontSize        =   8.25
  81.       FontStrikethru  =   0   'False
  82.       FontUnderline   =   0   'False
  83.       Height          =   360
  84.       Index           =   2
  85.       Left            =   3000
  86.       TabIndex        =   5
  87.       Top             =   0
  88.       Width           =   1536
  89.    End
  90.    Begin CommandButton TopBar 
  91.       Caption         =   "Book&mark"
  92.       FontBold        =   0   'False
  93.       FontItalic      =   0   'False
  94.       FontName        =   "MS Sans Serif"
  95.       FontSize        =   8.25
  96.       FontStrikethru  =   0   'False
  97.       FontUnderline   =   0   'False
  98.       Height          =   360
  99.       Index           =   3
  100.       Left            =   4500
  101.       TabIndex        =   4
  102.       Top             =   0
  103.       Width           =   1536
  104.    End
  105.    Begin CommandButton TopBar 
  106.       Caption         =   "&Notes"
  107.       FontBold        =   0   'False
  108.       FontItalic      =   0   'False
  109.       FontName        =   "MS Sans Serif"
  110.       FontSize        =   8.25
  111.       FontStrikethru  =   0   'False
  112.       FontUnderline   =   0   'False
  113.       Height          =   360
  114.       Index           =   4
  115.       Left            =   6000
  116.       TabIndex        =   3
  117.       Top             =   0
  118.       Width           =   1536
  119.    End
  120.    Begin CommandButton TopBar 
  121.       Caption         =   "&Library"
  122.       FontBold        =   0   'False
  123.       FontItalic      =   0   'False
  124.       FontName        =   "MS Sans Serif"
  125.       FontSize        =   8.25
  126.       FontStrikethru  =   0   'False
  127.       FontUnderline   =   0   'False
  128.       Height          =   360
  129.       Index           =   5
  130.       Left            =   7500
  131.       TabIndex        =   2
  132.       Top             =   0
  133.       Width           =   1530
  134.    End
  135.    Begin CommandButton TopBar 
  136.       Caption         =   "View &Text"
  137.       FontBold        =   0   'False
  138.       FontItalic      =   0   'False
  139.       FontName        =   "MS Sans Serif"
  140.       FontSize        =   8.25
  141.       FontStrikethru  =   0   'False
  142.       FontUnderline   =   0   'False
  143.       Height          =   360
  144.       Index           =   0
  145.       Left            =   0
  146.       TabIndex        =   1
  147.       Top             =   0
  148.       Width           =   1530
  149.    End
  150.    Begin CommandButton TopBar 
  151.       Caption         =   "&Wordprocessor"
  152.       FontBold        =   0   'False
  153.       FontItalic      =   0   'False
  154.       FontName        =   "MS Sans Serif"
  155.       FontSize        =   8.25
  156.       FontStrikethru  =   0   'False
  157.       FontUnderline   =   0   'False
  158.       Height          =   360
  159.       Index           =   6
  160.       Left            =   9000
  161.       TabIndex        =   0
  162.       Top             =   0
  163.       Width           =   1530
  164.    End
  165.    Begin Menu menu_file 
  166.       Caption         =   "&File"
  167.       Begin Menu menu_print 
  168.          Caption         =   "&Print"
  169.          Begin Menu menu_bookmarks 
  170.             Caption         =   "&Bookmarks..."
  171.          End
  172.          Begin Menu search_list 
  173.             Caption         =   "&Search list..."
  174.          End
  175.       End
  176.       Begin Menu menu_print_setup 
  177.          Caption         =   "P&rint setup..."
  178.       End
  179.       Begin Menu blank 
  180.          Caption         =   "-"
  181.       End
  182.       Begin Menu menu_preferences 
  183.          Caption         =   "Pre&ferences..."
  184.          Enabled         =   0   'False
  185.          Visible         =   0   'False
  186.       End
  187.       Begin Menu menu_exit 
  188.          Caption         =   "E&xit"
  189.          Shortcut        =   ^Q
  190.       End
  191.    End
  192.    Begin Menu menu_view 
  193.       Caption         =   "V&iew"
  194.       Begin Menu menu_book 
  195.          Caption         =   "&Book"
  196.       End
  197.       Begin Menu menu_Wordprocessor 
  198.          Caption         =   "&Wordprocessor"
  199.       End
  200.       Begin Menu menu_search_list 
  201.          Caption         =   "&Search list..."
  202.       End
  203.       Begin Menu menu_retrace_steps 
  204.          Caption         =   "&Retrace steps..."
  205.       End
  206.    End
  207.    Begin Menu menu_search 
  208.       Caption         =   "&Search"
  209.       Begin Menu Title_search 
  210.          Caption         =   "&Title..."
  211.       End
  212.       Begin Menu Simple_search 
  213.          Caption         =   "&Simple..."
  214.       End
  215.       Begin Menu Complex_search 
  216.          Caption         =   "&Complex..."
  217.       End
  218.       Begin Menu Field_search 
  219.          Caption         =   "&Field"
  220.          Begin Menu play_type_search 
  221.             Caption         =   "&Play type..."
  222.          End
  223.          Begin Menu scene_search 
  224.             Caption         =   "&Scene..."
  225.          End
  226.          Begin Menu song_search 
  227.             Caption         =   "S&ong"
  228.          End
  229.          Begin Menu soliloquy_search 
  230.             Caption         =   "So&liloquy..."
  231.          End
  232.          Begin Menu imagery_search 
  233.             Caption         =   "Selected &imagery..."
  234.          End
  235.       End
  236.    End
  237.    Begin Menu menu_help 
  238.       Caption         =   "&Help"
  239.       Begin Menu help_shakespeare 
  240.          Caption         =   "&Using The Complete Works"
  241.       End
  242.       Begin Menu help_wordprocessor 
  243.          Caption         =   "Using the &Word processor"
  244.       End
  245.       Begin Menu blank1 
  246.          Caption         =   "-"
  247.       End
  248.       Begin Menu help_about 
  249.          Caption         =   "&About..."
  250.       End
  251.    End
  252. End
  253. Declare Function GetWindowWord Lib "user.exe" (ByVal window As Integer, ByVal offset As Integer) As Integer
  254. Declare Sub Ctl3dRegister Lib "ctl3d.dll" (ByVal instance As Integer)
  255. Declare Sub Ctl3dAutoSubclass Lib "ctl3d.dll" (ByVal instance As Integer)
  256. Declare Sub Ctl3dUnRegister Lib "ctl3d.dll" (ByVal instance As Integer)
  257. Dim zone As String
  258. Dim ciCommand   As CursorInfo
  259.  
  260. Sub Animation1_AnimStop (Reason As Long)
  261. 'Animation1.BeginFade = cut
  262. do_command (zone)
  263. form3.Timer1.Enabled = True
  264.  
  265. End Sub
  266.  
  267. Sub Command1_Click (index As Integer)
  268. Select Case index
  269. Case 0
  270. 'form3.Animation1.Visible = False
  271. form3.Hide
  272. Case 1
  273. complexsearch.Show
  274. Case 2
  275. End Select
  276. End Sub
  277.  
  278. Sub Command3D1_Click (index As Integer)
  279.  hide_all
  280.  process_zone (zone_command(index))
  281.  
  282. End Sub
  283.  
  284. Sub Complex_search_Click ()
  285.     success% = SetWindowPos(complexsearch.hWnd, HWND_TOPMOST, 0, 0, 0, 0, TOPFLAGS)
  286.  
  287.  complexsearch.Show
  288.  
  289. End Sub
  290.  
  291. Sub Form_Load ()
  292.     'hInstance% = GetWindowWord(hWnd, GWW_HINSTANCE)
  293.     'Ctl3dRegister (hInstance%)
  294.     'Ctl3dAutoSubclass (hInstance%)
  295.     'MakeCursor form3.Command3D1(0).hWnd, picCursor1, picCursorMask1, ciCommand
  296.     'Unload form2
  297.     'form2.Refresh
  298. 'form3.Animation1.PositionFrame = 36
  299. 'form3.Animation1.EndFrame = 51
  300. 'form3.Animation1.Play = True
  301.     form3.Refresh
  302. form2.Timer1.Enabled = False
  303. 'timer2.Enabled = True
  304. End Sub
  305.  
  306. Sub Form_Resize ()
  307. If form3.Width < 1000 Then
  308. modalviewer.Hide
  309. choosesearch.Hide
  310. bookmark.Hide
  311. wordp.Hide
  312. List.Hide
  313. 'notepad.Hide
  314. formmain.Hide
  315. End If
  316. b = form3.Width / (screen.TwipsPerPixelX * 7)
  317. For a = 0 To 6
  318. form3.TopBar(a).Width = b
  319. form3.TopBar(a).Left = a * b
  320. 'topbar(a).FontSize = 9.75
  321. Next a
  322. If virgin1 = 0 Then
  323. timer2.Enabled = True
  324. form3.Refresh
  325. Unload form2
  326. End If
  327. virgin1 = 1
  328. End Sub
  329.  
  330. Sub Form_Unload (Cancel As Integer)
  331. End
  332. End Sub
  333.  
  334. Sub help_about_Click ()
  335. hide_all
  336. about.Show
  337.  
  338. End Sub
  339.  
  340. Sub help_shakespeare_Click ()
  341.   hide_all
  342. Const HELP_KEY = &H101
  343.   
  344.  form3.CMDialog1.HelpFile = cd_drive + "\LIBRARY\EXE\shakehlp.HLP"
  345.   form3.CMDialog1.HelpContext = 3
  346.   form3.CMDialog1.HelpCommand = 3
  347.   form3.CMDialog1.Action = 6
  348.  
  349.  
  350.  
  351. End Sub
  352.  
  353. Sub help_wordprocessor_Click ()
  354.   hide_all
  355.   'Specify the help file to be opened.
  356.   form3.CMDialog1.HelpFile = cd_drive + "\LIBRARY\EXE\shakword.HLP"
  357.   'When WinHelp.exe is executed, help for a specified
  358.   'keyword will be displayed.
  359.   form3.CMDialog1.HelpCommand = 3
  360.   form3.CMDialog1.HelpContext = 3
  361.   'Specify the keyword
  362.   'CMDialog1.HelpKey = "MouseDown"
  363.   'Execute WinHelp.exe
  364.   form3.CMDialog1.Action = 6
  365.  
  366.  
  367.  
  368. End Sub
  369.  
  370. Sub imagery_search_Click ()
  371.     hide_all
  372.     ChDrive cd_drive
  373.     ChDir "\library\exe"
  374.     
  375.     ImagerySearch filenum%, linenum%
  376.      If filenum% > 0 Then
  377.     modalviewer.modal.Value = filenum%
  378.     Call view_text(0)
  379.     goto_line (linenum%)
  380.     End If
  381.  
  382. End Sub
  383.  
  384. Sub menu_book_Click ()
  385. do_command ("OPEN")
  386.  
  387. End Sub
  388.  
  389. Sub menu_bookmarks_Click ()
  390. hide_all
  391. form3.CMDialog1.Action = 5
  392. If form3.CMDialog1.CancelError <> True Then
  393. For a = 0 To bookmark.List1.ListCount - 1
  394. printer.Print bookmark.List1.List(a)
  395. 'Print #1, Mid$(Str$(bookmark.List1.ItemData(a)), 2, 10)
  396. Next a
  397. printer.EndDoc
  398. End If
  399.  
  400. End Sub
  401.  
  402. Sub menu_exit_Click ()
  403. End
  404.  
  405. End Sub
  406.  
  407. Sub menu_open_Click ()
  408. hide_all
  409. On Error GoTo leave:
  410. form3.CMDialog1.InitDir = "c:\library"
  411. form3.CMDialog1.Filename = "CDAUTHOR.BMK"
  412. form3.CMDialog1.Filter = "*.bmk,Bookmarks"
  413. form3.CMDialog1.Action = 1
  414.  If form3.CMDialog1.CancelError <> True Then
  415. Open form3.CMDialog1.Filename For Input As #1
  416. bookmark.List1.Clear
  417. Do
  418. Line Input #1, a$
  419. Line Input #1, b$
  420.  bookmark.List1.AddItem (a$)
  421. bookmark.List1.ItemData(bookmark.List1.NewIndex) = Val(b$)
  422. Loop Until EOF(1)
  423. Close #1
  424. End If
  425. Exit Sub
  426. leave:
  427. Close #1
  428. Exit Sub
  429.  
  430. End Sub
  431.  
  432. Sub menu_preferences_Click ()
  433. success% = SetWindowPos(preferences.hWnd, HWND_TOPMOST, 0, 0, 0, 0, TOPFLAGS)
  434. preferences.Show
  435.  
  436. End Sub
  437.  
  438. Sub menu_print_setup_Click ()
  439. hide_all
  440. form3.CMDialog1.Action = 5
  441.  
  442. End Sub
  443.  
  444. Sub menu_retrace_steps_Click ()
  445. retrace.Show
  446.  
  447. End Sub
  448.  
  449. Sub menu_save_as_Click ()
  450. On Error Resume Next
  451. hide_all
  452. form3.CMDialog1.InitDir = "c:\library"
  453. form3.CMDialog1.Filename = "CDAUTHOR.BMK"
  454. form3.CMDialog1.Filter = "*.bmk,Bookmarks"
  455. form3.CMDialog1.Action = 2
  456. If form3.CMDialog1.CancelError <> True Then
  457. Open form3.CMDialog1.Filename For Output As #1
  458. For a = 0 To bookmark.List1.ListCount - 1
  459. Print #1, bookmark.List1.List(a)
  460. Print #1, Mid$(Str$(bookmark.List1.ItemData(a)), 2, 10)
  461. Next a
  462. Close
  463. End If
  464.  
  465. End Sub
  466.  
  467. Sub menu_search_list_Click ()
  468. hide_all
  469. List.Show
  470.  
  471. End Sub
  472.  
  473. Sub menu_Wordprocessor_Click ()
  474. wordp.Show
  475.  
  476. End Sub
  477.  
  478. Sub play_type_search_Click ()
  479.     'hInstance% = GetWindowWord(hWnd, GWW_HINSTANCE)
  480.     'Ctl3dRegister (hInstance%)
  481.     'Ctl3dAutoSubclass (hInstance%)
  482. 'field_search (0)
  483.     hide_all
  484.     ChDrive cd_drive
  485.     ChDir "\library\exe"
  486.     filenum% = playsearch()
  487.     If filenum% > 1 Then
  488.     modalviewer.modal.Value = filenum%
  489.     Call view_text(0)
  490.     End If
  491.  
  492.  
  493. End Sub
  494.  
  495. Sub process_zone (zone_c)
  496.  
  497.  
  498. 'form3.Animation1.Play = False
  499. 'form3.Animation1.PositionFrame = 1
  500. Select Case preferences.Check3D1.Value
  501. Case True
  502. zone = zone_c
  503. Select Case zone_c
  504. Case "GLOSSARY"
  505. 'form3.Animation1.PositionFrame = 16
  506. 'form3.Animation1.EndFrame = 31
  507. 'form3.Animation1.Play = True
  508.  
  509. Case "SEARCH"
  510. 'form3.Animation1.PositionFrame = 66: ' 17
  511. 'form3.Animation1.EndFrame = 81: '32
  512. 'form3.Animation1.Play = True
  513. Case "BOOKSHELF"
  514. 'form3.Animation1.PositionFrame = 34
  515. 'form3.Animation1.EndFrame = 49
  516. 'form3.Animation1.Play = True
  517. Case "WORDPROCESSOR"
  518. 'form3.Animation1.PositionFrame = 49
  519. 'form3.Animation1.EndFrame = 65
  520. 'form3.Animation1.Play = True
  521. Case "FIELDSEARCH"
  522. 'form3.Animation1.PositionFrame = 66
  523. 'form3.Animation1.EndFrame = 81
  524. 'form3.Animation1.Play = True
  525.  
  526. Case "BOOKMARK"
  527. 'form3.Animation1.PositionFrame = 82
  528. 'form3.Animation1.EndFrame = 88
  529. 'form3.Animation1.Play = True
  530.  
  531. Case "MODALVIEWER"
  532. 'form3.Animation1.PositionFrame = 99
  533. 'form3.Animation1.EndFrame = 129
  534. 'form3.Animation1.Play = True
  535. Case "FIRE"
  536. 'form3.Animation1.PositionFrame = 2
  537. 'form3.Animation1.EndFrame = 17
  538. 'form3.Animation1.Play = True
  539.  
  540.  
  541. Case "SOUND"
  542.     If preferences.Audio.Value = True Then
  543.      'MMControl1.Command = "prev"
  544.      'MMControl1.Command = "play"
  545.      End If
  546.  
  547. End Select
  548.  
  549. Case False
  550.  do_command (zone_c)
  551. End Select
  552.  
  553. End Sub
  554.  
  555. Sub scene_search_Click ()
  556. hide_all
  557. 'field_search (1)
  558.     ChDrive cd_drive
  559.     ChDir "\library\exe"
  560.       filenum% = scenesearch()
  561.     If filenum% > 1 Then
  562. modalviewer.modal.Value = filenum%
  563.     Call view_text(0)
  564.     End If
  565.  
  566.  
  567. End Sub
  568.  
  569. Sub search_list_Click ()
  570. hide_all
  571. form3.CMDialog1.Action = 5
  572. If form3.CMDialog1.CancelError <> True Then
  573. For a = 0 To List.List1.ListCount - 1
  574. printer.Print List.List1.List(a)
  575. 'Print #1, Mid$(Str$(bookmark.List1.ItemData(a)), 2, 10)
  576. Next a
  577. printer.EndDoc
  578. End If
  579.  
  580. End Sub
  581.  
  582. Sub Simple_search_Click ()
  583.  
  584. success% = SetWindowPos(simplesearch.hWnd, HWND_TOPMOST, 0, 0, 0, 0, TOPFLAGS)
  585. simplesearch.Show
  586. 'hide_all
  587. 'search_words(0) = InputBox$("Enter the WORD you wish to search for", "Simple Search", "")
  588. 'If search_words(0) <> "" Then Call free_text_search("WORD", 0, 0)
  589.  
  590.  
  591. End Sub
  592.  
  593. Sub soliloquy_search_Click ()
  594.  
  595. hide_all
  596.     ChDrive cd_drive
  597.     ChDir "\library\exe"
  598.  
  599. sol_search
  600.  
  601. End Sub
  602.  
  603. Sub song_search_Click ()
  604.  hide_all
  605.     ChDrive cd_drive
  606.     ChDir "\library\exe"
  607.  
  608.  song_search
  609.  
  610.  
  611. End Sub
  612.  
  613. Sub timer_2 ()
  614. End Sub
  615.  
  616. Sub Timer1_Timer ()
  617. 'form3.Animation1.PositionFrame = 3
  618. form3.Timer1.Enabled = False
  619.  
  620. End Sub
  621.  
  622. Sub Timer2_Timer ()
  623. process_zone ("FIRE")
  624. timer2.Enabled = False
  625. End Sub
  626.  
  627. Sub Title_search_Click ()
  628.  
  629. success% = SetWindowPos(titlesearch.hWnd, HWND_TOPMOST, 0, 0, 0, 0, TOPFLAGS)
  630. titlesearch.Show
  631. 'hide_all
  632. 'Do
  633. 'search_words(0) = InputBox$("Enter ONE Word only                                            Enter Author's name to display Author(Biography) and works by that author.                                   Enter keyword from title to display all titles containing this word.                                             Click on OK to start the search", "Title or Author Search", "")
  634. 'If search_words(0) <> "" Then
  635. ' Call free_text_search("TITLE", 0, 0)
  636. ' Else
  637. ' successful = 1
  638. ' End If
  639.  
  640.  
  641. 'Loop Until successful = 1
  642.  
  643. End Sub
  644.  
  645. Sub TopBar_Click (index As Integer)
  646. do_command (buttons_command(index))
  647. End Sub
  648.  
  649.